Optimal. Leaf size=261 \[ \frac {(163 B-283 C) \tan ^{-1}\left (\frac {\sqrt {a} \tan (c+d x)}{\sqrt {2} \sqrt {a \sec (c+d x)+a}}\right )}{16 \sqrt {2} a^{5/2} d}+\frac {(475 B-787 C) \tan (c+d x) \sqrt {a \sec (c+d x)+a}}{240 a^3 d}-\frac {(85 B-157 C) \tan (c+d x) \sec ^2(c+d x)}{80 a^2 d \sqrt {a \sec (c+d x)+a}}-\frac {(985 B-1729 C) \tan (c+d x)}{120 a^2 d \sqrt {a \sec (c+d x)+a}}+\frac {(B-C) \tan (c+d x) \sec ^4(c+d x)}{4 d (a \sec (c+d x)+a)^{5/2}}+\frac {(13 B-21 C) \tan (c+d x) \sec ^3(c+d x)}{16 a d (a \sec (c+d x)+a)^{3/2}} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.93, antiderivative size = 261, normalized size of antiderivative = 1.00, number of steps used = 8, number of rules used = 7, integrand size = 42, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.167, Rules used = {4072, 4019, 4021, 4010, 4001, 3795, 203} \[ -\frac {(85 B-157 C) \tan (c+d x) \sec ^2(c+d x)}{80 a^2 d \sqrt {a \sec (c+d x)+a}}+\frac {(163 B-283 C) \tan ^{-1}\left (\frac {\sqrt {a} \tan (c+d x)}{\sqrt {2} \sqrt {a \sec (c+d x)+a}}\right )}{16 \sqrt {2} a^{5/2} d}+\frac {(475 B-787 C) \tan (c+d x) \sqrt {a \sec (c+d x)+a}}{240 a^3 d}-\frac {(985 B-1729 C) \tan (c+d x)}{120 a^2 d \sqrt {a \sec (c+d x)+a}}+\frac {(B-C) \tan (c+d x) \sec ^4(c+d x)}{4 d (a \sec (c+d x)+a)^{5/2}}+\frac {(13 B-21 C) \tan (c+d x) \sec ^3(c+d x)}{16 a d (a \sec (c+d x)+a)^{3/2}} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 203
Rule 3795
Rule 4001
Rule 4010
Rule 4019
Rule 4021
Rule 4072
Rubi steps
\begin {align*} \int \frac {\sec ^4(c+d x) \left (B \sec (c+d x)+C \sec ^2(c+d x)\right )}{(a+a \sec (c+d x))^{5/2}} \, dx &=\int \frac {\sec ^5(c+d x) (B+C \sec (c+d x))}{(a+a \sec (c+d x))^{5/2}} \, dx\\ &=\frac {(B-C) \sec ^4(c+d x) \tan (c+d x)}{4 d (a+a \sec (c+d x))^{5/2}}+\frac {\int \frac {\sec ^4(c+d x) \left (4 a (B-C)-\frac {1}{2} a (5 B-13 C) \sec (c+d x)\right )}{(a+a \sec (c+d x))^{3/2}} \, dx}{4 a^2}\\ &=\frac {(B-C) \sec ^4(c+d x) \tan (c+d x)}{4 d (a+a \sec (c+d x))^{5/2}}+\frac {(13 B-21 C) \sec ^3(c+d x) \tan (c+d x)}{16 a d (a+a \sec (c+d x))^{3/2}}+\frac {\int \frac {\sec ^3(c+d x) \left (\frac {3}{2} a^2 (13 B-21 C)-\frac {1}{4} a^2 (85 B-157 C) \sec (c+d x)\right )}{\sqrt {a+a \sec (c+d x)}} \, dx}{8 a^4}\\ &=\frac {(B-C) \sec ^4(c+d x) \tan (c+d x)}{4 d (a+a \sec (c+d x))^{5/2}}+\frac {(13 B-21 C) \sec ^3(c+d x) \tan (c+d x)}{16 a d (a+a \sec (c+d x))^{3/2}}-\frac {(85 B-157 C) \sec ^2(c+d x) \tan (c+d x)}{80 a^2 d \sqrt {a+a \sec (c+d x)}}+\frac {\int \frac {\sec ^2(c+d x) \left (-\frac {1}{2} a^3 (85 B-157 C)+\frac {1}{8} a^3 (475 B-787 C) \sec (c+d x)\right )}{\sqrt {a+a \sec (c+d x)}} \, dx}{20 a^5}\\ &=\frac {(B-C) \sec ^4(c+d x) \tan (c+d x)}{4 d (a+a \sec (c+d x))^{5/2}}+\frac {(13 B-21 C) \sec ^3(c+d x) \tan (c+d x)}{16 a d (a+a \sec (c+d x))^{3/2}}-\frac {(85 B-157 C) \sec ^2(c+d x) \tan (c+d x)}{80 a^2 d \sqrt {a+a \sec (c+d x)}}+\frac {(475 B-787 C) \sqrt {a+a \sec (c+d x)} \tan (c+d x)}{240 a^3 d}+\frac {\int \frac {\sec (c+d x) \left (\frac {1}{16} a^4 (475 B-787 C)-\frac {1}{8} a^4 (985 B-1729 C) \sec (c+d x)\right )}{\sqrt {a+a \sec (c+d x)}} \, dx}{30 a^6}\\ &=\frac {(B-C) \sec ^4(c+d x) \tan (c+d x)}{4 d (a+a \sec (c+d x))^{5/2}}+\frac {(13 B-21 C) \sec ^3(c+d x) \tan (c+d x)}{16 a d (a+a \sec (c+d x))^{3/2}}-\frac {(985 B-1729 C) \tan (c+d x)}{120 a^2 d \sqrt {a+a \sec (c+d x)}}-\frac {(85 B-157 C) \sec ^2(c+d x) \tan (c+d x)}{80 a^2 d \sqrt {a+a \sec (c+d x)}}+\frac {(475 B-787 C) \sqrt {a+a \sec (c+d x)} \tan (c+d x)}{240 a^3 d}+\frac {(163 B-283 C) \int \frac {\sec (c+d x)}{\sqrt {a+a \sec (c+d x)}} \, dx}{32 a^2}\\ &=\frac {(B-C) \sec ^4(c+d x) \tan (c+d x)}{4 d (a+a \sec (c+d x))^{5/2}}+\frac {(13 B-21 C) \sec ^3(c+d x) \tan (c+d x)}{16 a d (a+a \sec (c+d x))^{3/2}}-\frac {(985 B-1729 C) \tan (c+d x)}{120 a^2 d \sqrt {a+a \sec (c+d x)}}-\frac {(85 B-157 C) \sec ^2(c+d x) \tan (c+d x)}{80 a^2 d \sqrt {a+a \sec (c+d x)}}+\frac {(475 B-787 C) \sqrt {a+a \sec (c+d x)} \tan (c+d x)}{240 a^3 d}-\frac {(163 B-283 C) \operatorname {Subst}\left (\int \frac {1}{2 a+x^2} \, dx,x,-\frac {a \tan (c+d x)}{\sqrt {a+a \sec (c+d x)}}\right )}{16 a^2 d}\\ &=\frac {(163 B-283 C) \tan ^{-1}\left (\frac {\sqrt {a} \tan (c+d x)}{\sqrt {2} \sqrt {a+a \sec (c+d x)}}\right )}{16 \sqrt {2} a^{5/2} d}+\frac {(B-C) \sec ^4(c+d x) \tan (c+d x)}{4 d (a+a \sec (c+d x))^{5/2}}+\frac {(13 B-21 C) \sec ^3(c+d x) \tan (c+d x)}{16 a d (a+a \sec (c+d x))^{3/2}}-\frac {(985 B-1729 C) \tan (c+d x)}{120 a^2 d \sqrt {a+a \sec (c+d x)}}-\frac {(85 B-157 C) \sec ^2(c+d x) \tan (c+d x)}{80 a^2 d \sqrt {a+a \sec (c+d x)}}+\frac {(475 B-787 C) \sqrt {a+a \sec (c+d x)} \tan (c+d x)}{240 a^3 d}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A] time = 2.87, size = 177, normalized size = 0.68 \[ \frac {\tan (c+d x) \left (\sqrt {1-\sec (c+d x)} \left (160 (B-C) \sec ^3(c+d x)-32 (25 B-49 C) \sec ^2(c+d x)-5 (503 B-911 C) \sec (c+d x)-1495 B+96 C \sec ^4(c+d x)+2671 C\right )+30 \sqrt {2} (163 B-283 C) \cos ^4\left (\frac {1}{2} (c+d x)\right ) \sec ^2(c+d x) \tanh ^{-1}\left (\frac {\sqrt {1-\sec (c+d x)}}{\sqrt {2}}\right )\right )}{240 d \sqrt {1-\sec (c+d x)} (a (\sec (c+d x)+1))^{5/2}} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [A] time = 0.50, size = 596, normalized size = 2.28 \[ \left [\frac {15 \, \sqrt {2} {\left ({\left (163 \, B - 283 \, C\right )} \cos \left (d x + c\right )^{5} + 3 \, {\left (163 \, B - 283 \, C\right )} \cos \left (d x + c\right )^{4} + 3 \, {\left (163 \, B - 283 \, C\right )} \cos \left (d x + c\right )^{3} + {\left (163 \, B - 283 \, C\right )} \cos \left (d x + c\right )^{2}\right )} \sqrt {-a} \log \left (-\frac {2 \, \sqrt {2} \sqrt {-a} \sqrt {\frac {a \cos \left (d x + c\right ) + a}{\cos \left (d x + c\right )}} \cos \left (d x + c\right ) \sin \left (d x + c\right ) - 3 \, a \cos \left (d x + c\right )^{2} - 2 \, a \cos \left (d x + c\right ) + a}{\cos \left (d x + c\right )^{2} + 2 \, \cos \left (d x + c\right ) + 1}\right ) - 4 \, {\left ({\left (1495 \, B - 2671 \, C\right )} \cos \left (d x + c\right )^{4} + 5 \, {\left (503 \, B - 911 \, C\right )} \cos \left (d x + c\right )^{3} + 32 \, {\left (25 \, B - 49 \, C\right )} \cos \left (d x + c\right )^{2} - 160 \, {\left (B - C\right )} \cos \left (d x + c\right ) - 96 \, C\right )} \sqrt {\frac {a \cos \left (d x + c\right ) + a}{\cos \left (d x + c\right )}} \sin \left (d x + c\right )}{960 \, {\left (a^{3} d \cos \left (d x + c\right )^{5} + 3 \, a^{3} d \cos \left (d x + c\right )^{4} + 3 \, a^{3} d \cos \left (d x + c\right )^{3} + a^{3} d \cos \left (d x + c\right )^{2}\right )}}, -\frac {15 \, \sqrt {2} {\left ({\left (163 \, B - 283 \, C\right )} \cos \left (d x + c\right )^{5} + 3 \, {\left (163 \, B - 283 \, C\right )} \cos \left (d x + c\right )^{4} + 3 \, {\left (163 \, B - 283 \, C\right )} \cos \left (d x + c\right )^{3} + {\left (163 \, B - 283 \, C\right )} \cos \left (d x + c\right )^{2}\right )} \sqrt {a} \arctan \left (\frac {\sqrt {2} \sqrt {\frac {a \cos \left (d x + c\right ) + a}{\cos \left (d x + c\right )}} \cos \left (d x + c\right )}{\sqrt {a} \sin \left (d x + c\right )}\right ) + 2 \, {\left ({\left (1495 \, B - 2671 \, C\right )} \cos \left (d x + c\right )^{4} + 5 \, {\left (503 \, B - 911 \, C\right )} \cos \left (d x + c\right )^{3} + 32 \, {\left (25 \, B - 49 \, C\right )} \cos \left (d x + c\right )^{2} - 160 \, {\left (B - C\right )} \cos \left (d x + c\right ) - 96 \, C\right )} \sqrt {\frac {a \cos \left (d x + c\right ) + a}{\cos \left (d x + c\right )}} \sin \left (d x + c\right )}{480 \, {\left (a^{3} d \cos \left (d x + c\right )^{5} + 3 \, a^{3} d \cos \left (d x + c\right )^{4} + 3 \, a^{3} d \cos \left (d x + c\right )^{3} + a^{3} d \cos \left (d x + c\right )^{2}\right )}}\right ] \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [A] time = 3.53, size = 439, normalized size = 1.68 \[ -\frac {\frac {{\left ({\left ({\left (15 \, {\left (\frac {2 \, {\left (\sqrt {2} B a^{2} \mathrm {sgn}\left (\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} - 1\right ) - \sqrt {2} C a^{2} \mathrm {sgn}\left (\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} - 1\right )\right )} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2}}{a^{2}} + \frac {21 \, \sqrt {2} B a^{2} \mathrm {sgn}\left (\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} - 1\right ) - 29 \, \sqrt {2} C a^{2} \mathrm {sgn}\left (\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} - 1\right )}{a^{2}}\right )} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} - \frac {3685 \, \sqrt {2} B a^{2} \mathrm {sgn}\left (\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} - 1\right ) - 6733 \, \sqrt {2} C a^{2} \mathrm {sgn}\left (\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} - 1\right )}{a^{2}}\right )} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} + \frac {5 \, {\left (1133 \, \sqrt {2} B a^{2} \mathrm {sgn}\left (\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} - 1\right ) - 1973 \, \sqrt {2} C a^{2} \mathrm {sgn}\left (\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} - 1\right )\right )}}{a^{2}}\right )} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} - \frac {15 \, {\left (155 \, \sqrt {2} B a^{2} \mathrm {sgn}\left (\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} - 1\right ) - 291 \, \sqrt {2} C a^{2} \mathrm {sgn}\left (\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} - 1\right )\right )}}{a^{2}}\right )} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )}{{\left (a \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} - a\right )}^{2} \sqrt {-a \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} + a}} - \frac {15 \, {\left (163 \, \sqrt {2} B - 283 \, \sqrt {2} C\right )} \log \left ({\left | -\sqrt {-a} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) + \sqrt {-a \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} + a} \right |}\right )}{\sqrt {-a} a^{2} \mathrm {sgn}\left (\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} - 1\right )}}{480 \, d} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [B] time = 1.99, size = 985, normalized size = 3.77 \[ \text {result too large to display} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [F(-1)] time = 0.00, size = 0, normalized size = 0.00 \[ \text {Timed out} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [F] time = 0.00, size = -1, normalized size = -0.00 \[ \int \frac {\frac {B}{\cos \left (c+d\,x\right )}+\frac {C}{{\cos \left (c+d\,x\right )}^2}}{{\cos \left (c+d\,x\right )}^4\,{\left (a+\frac {a}{\cos \left (c+d\,x\right )}\right )}^{5/2}} \,d x \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [F] time = 0.00, size = 0, normalized size = 0.00 \[ \int \frac {\left (B + C \sec {\left (c + d x \right )}\right ) \sec ^{5}{\left (c + d x \right )}}{\left (a \left (\sec {\left (c + d x \right )} + 1\right )\right )^{\frac {5}{2}}}\, dx \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________